<?php if (!defined('THINK_PATH')) exit(); /*a:1:{s:71:"D:\Code\matian\matian\application\admin\view\bootstrap\index\index.html";i:1496854212;}*/ ?>
<!--
*
*  INSPINIA - Responsive Admin Theme
*  version 2.6.2
*
-->
<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <title> 后台</title>

    <link href="/css/bootstrap.min.css" rel="stylesheet">
    <link href="/font-awesome/css/font-awesome.css" rel="stylesheet">

    <!-- Toastr style -->
    <link href="/css/plugins/toastr/toastr.min.css" rel="stylesheet">

    <!-- Gritter -->
    <link href="/js/plugins/gritter/jquery.gritter.css" rel="stylesheet">
    <!--<link href="/css/plugins/footable/footable.core.css" rel="stylesheet">-->
    <link href="/css/plugins/footable/footable.bootstrap.css" rel="stylesheet">
    <link href="/css/plugins/datetimepicker/bootstrap-datetimepicker.min.css" rel="stylesheet">
    <link href="/css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
    <link href="/css/plugins/ladda/ladda-themeless.min.css" rel="stylesheet">
    <link href="/css/animate.css" rel="stylesheet">
    <link href="/webuploader/webuploader.css" rel="stylesheet">
    <link href="/css/style.css" rel="stylesheet">
    <link href="/css/plugins/jsTree/style.min.css" rel="stylesheet">
    <style type="text/css">
        .hr-line-dashed {
            margin: 6px 0;
        }

        .form-group {
            margin-bottom: 5px;
        }
    </style>
</head>

<body>
<div id="wrapper">
    <nav class="navbar-default navbar-static-side" role="navigation">
        <div class="sidebar-collapse">
            <ul class="nav metismenu" id="side-menu">
                <li class="nav-header">
                    <div class="dropdown profile-element">
                        <span>
                            <img alt="image" class="img-circle admin-logo" src="<?php echo !empty($avatar)?$avatar:'/images/avatar.jpg'; ?>"
                                 onerror='this.src="/images/avatar.jpg"'/>
                        </span>
                        <a data-toggle="dropdown" class="dropdown-toggle" href="#">
                            <span class="clear"> <span class="block m-t-xs"> <strong class="font-bold">
                                <?php echo $loginName; ?>
                            </strong>
                             </span> <span class="text-muted text-xs block"><?php echo $roleName; ?> <b
                                    class="caret"></b></span> </span> </a>
                        <ul class="dropdown-menu animated fadeInRight m-t-xs">
                            <li><a href="#<?php echo U('member/info'); ?>">个人信息</a></li>
                            <li><a href="#<?php echo U('member/pwd'); ?>">修改密码</a></li>
                            <li class="divider"></li>
                            <li><a id="sys_logoff2">退出</a></li>
                        </ul>
                    </div>
                    <div class="logo-element">
                        后台管理
                    </div>
                </li>
                <?php $i = '-1'; if(is_array($bag['menuList'])): foreach($bag['menuList'] as $vok=>$vo): $i = $i+1; ?>
                <li <?php echo ($i==0)?'class="active"':''; ?>>
                    <a href="<?php echo strpos($vok,'#') === 0?'javascript:void(0)':'#'.U($vok); ?>">
                        <i class="fa fa-th-large"></i>
                        <span class="nav-label"><?php echo $vo['title']; ?></span>
                        <?php if(!empty($vo['subs'])): ?>
                        <span class="fa arrow"></span>
                        <?php endif; ?>
                    </a>
                    <?php if(!empty($vo['subs'])): ?>
                    <ul class="nav nav-second-level collapse">
                        <?php if(is_array($vo['subs'])): foreach($vo['subs'] as $jok=>$jo): ?>
                        <li>
                            <a href="<?php echo strpos($jok,'#') === 0?'javascript:void(0)':'#'.U($jok); ?>">
                                <?php echo $jo['title']; if(!empty($jo['subs'])): ?>
                                <span class="fa arrow"></span>
                                <?php endif; ?>
                            </a>
                            <?php if(!empty($jo['subs'])): ?>
                            <ul class="nav nav-third-level collapse">
                                <?php if(is_array($jo['subs'])): foreach($jo['subs'] as $kok=>$ko): ?>
                                <li>
                                    <a href="<?php echo strpos($kok,'#') === 0?'javascript:void(0)':'#'.U($kok); ?>"><?php echo $ko['title']; ?></a>
                                </li>
                                <?php endforeach; endif; ?>
                            </ul>
                            <?php endif; ?>
                        </li>
                        <?php endforeach; endif; ?>
                    </ul>
                    <?php endif; ?>
                </li>
                <?php endforeach; endif; ?>
            </ul>
        </div>
    </nav>
    <div id="page-wrapper" class="gray-bg dashbard-1">
        <div class="row border-bottom">
            <nav class="navbar navbar-static-top" role="navigation" style="margin-bottom: 0">
                <div class="navbar-header">
                    <a class="navbar-minimalize minimalize-styl-2 btn btn-primary " href="javascript:void(0)"><i
                            class="fa fa-bars"></i>
                    </a>
                    <!--<form role="search" class="navbar-form-custom" action="search_results.html">-->
                    <!--<div class="form-group">-->
                    <!--<input type="text" placeholder="输入关键字搜索..." class="form-control"-->
                    <!--name="top-search" id="top-search">-->
                    <!--</div>-->
                    <!--</form>-->
                </div>
                <ul class="nav navbar-top-links navbar-right">
                    <li>
                        <a href="javascript:void(0)" id="sys_logoff"><i class="fa fa-sign-out"></i> 退出</a>
                    </li>
                </ul>
            </nav>
        </div>
        <div id="main_content"></div>
    </div>
</div>

<div id="imgmaster1">
</div>
<div id="imgmaster2">
    <img src="javascript:void(0)" id="imgmaster2-1"/>
    <span id="imgmaster2-closebtn" onclick="$('#imgmaster1,#imgmaster2').hide()">×</span>
</div>


<div class="modal inmodal" id="__yy_export_window" tabindex="-1" role="dialog" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content animated fadeIn">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span
                        class="sr-only">Close</span></button>
                <i class="fa fa-file modal-icon"></i>
                <h4 class="modal-title">导出Excel</h4>
            </div>
            <div class="modal-body">
                <p>

                    导出所有数据:导出查到记录的所有记录
                </p>
                <p>
                    导出当前页面:导出查到记录的第一页
                </p>
            </div>
            <div class="modal-footer">

                <button type="button" class="btn btn-success btn-export">导出当前页面</button>
                <button type="button" class="btn btn-primary btn-export btn-all-page">导出所有数据</button>
                <button type="button" class="btn btn-white" data-dismiss="modal">关闭</button>
            </div>
        </div>
    </div>
</div>


<script src="<?php echo U('index/options'); ?>"></script>
<!-- Mainly scripts -->
<script src="/js/jquery-2.1.1.js"></script>
<script src="/js/bootstrap.min.js"></script>
<script src="/js/plugins/metisMenu/jquery.metisMenu.js"></script>
<script src="/js/plugins/slimscroll/jquery.slimscroll.min.js"></script>

<!-- Flot -->
<script src="/js/plugins/flot/jquery.flot.js"></script>
<script src="/js/plugins/flot/jquery.flot.tooltip.min.js"></script>
<script src="/js/plugins/flot/jquery.flot.spline.js"></script>
<script src="/js/plugins/flot/jquery.flot.resize.js"></script>
<script src="/js/plugins/flot/jquery.flot.pie.js"></script>

<!-- Peity -->
<script src="/js/plugins/peity/jquery.peity.min.js"></script>

<!-- Custom and plugin javascript -->
<script src="/js/inspinia.js"></script>
<script src="/js/plugins/pace/pace.min.js" data-pace-options='{ "restartOnRequestAfter": true }'></script>

<!-- jQuery UI -->
<!--<script src="/js/plugins/jquery-ui/jquery-ui.min.js"></script>-->

<!-- GITTER -->
<script src="/js/plugins/gritter/jquery.gritter.min.js"></script>

<!-- Sparkline -->
<script src="/js/plugins/sparkline/jquery.sparkline.min.js"></script>

<!-- Sparkline demo data  -->
<!--<script src="/js/demo/sparkline-demo.js"></script>-->

<!-- ChartJS-->
<!--<script src="/js/plugins/chartJs/Chart.min.js"></script>-->

<!-- Toastr -->
<script src="/js/plugins/toastr/toastr.min.js"></script>
<script src="/js/plugins/datetimepicker/bootstrap-datetimepicker.js"></script>
<script src="/js/plugins/datetimepicker/locales/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="/js/plugins/footable/footable.js"></script>
<script src="/js/plugins/sweetalert/sweetalert.min.js"></script>
<script src="/js/plugins/validate/jquery.validate.js"></script>
<script src="/js/plugins/validate/messages_zh.js"></script>
<script src="/js/plugins/ladda/spin.min.js"></script>
<script src="/js/plugins/ladda/ladda.min.js"></script>
<script src="/js/plugins/ladda/ladda.jquery.min.js"></script>
<script src="/js/plugins/jsTree/jstree.min.js"></script>
<script type="text/javascript" src="/static/plupload/plupload.full.min.js"></script>
<script type="text/javascript" src="/static/js/json2.js"></script>
<script type="text/javascript" charset="utf-8" src="/static/ueditor/ueditor.config.js"></script>
<script type="text/javascript" charset="utf-8" src="/static/ueditor/editor_api.js"></script>
<script src="/js/app.js"></script>
<script>

    $(document).ready(function () {

        function loadPage(href) {
            $.get(href, function (rt) {
                $('#main_content').html(rt);
            });
        }

        function loadByHash() {
            if (location.hash) {
                var hash = location.hash;
                if (~hash.indexOf('#')) {
                    hash = hash.substring(1);
                    loadPage(hash);
                }
            } else {
                loadPage("<?php echo U('index/desktop'); ?>");
            }
        }

        loadByHash();
        window.addEventListener('hashchange', loadByHash, false);
        $('#sys_logoff,#sys_logoff2').click(function () {
            YMessager.confirm({
                title: '确定退出系统吗?',
                text: '退出后需要重新登录'
            }, function () {
                location.href = "<?php echo U('login/logoff'); ?>";
            });
        });

    });

    $('#imgmaster1,#imgmaster2').click(function () {
        $('#imgmaster1,#imgmaster2').hide();
    });
    function showBigImage(img, event) {
        $('#imgmaster1,#imgmaster2').show();
        $('#imgmaster2-1')[0].src = img.src;
        var height = $('#imgmaster2-1').height();
        var bodyHeight = document.documentElement.clientHeight;
        if (height > bodyHeight) {
            height = parseInt(bodyHeight * 0.9);
            $('#imgmaster2-1').height(height);
        }
        $('#imgmaster2').css({
            marginTop: -height / 2
        });
        if (event) {
            event.stopPropagation();
        }
    }

    (function () {
        var exportWindow = $("#__yy_export_window");
        exportWindow.on('click', 'button.btn-export', function () {
            var that = $('#__yy_export_window').data('current_dlg');
            if(that){
                var url = that.getRemoteUrl('export');
                var queryParams = that.getQueryParams();
                queryParams.title = that.getOption('title')||'';
                if ($(this).is('.btn-all-page')) {
                    queryParams.exportType = 'all';
                } else {
                    queryParams.exportType = 'page';
                }
                queryParams.exportOptions = that.getExportOptions();
                var exportParam = encodeURIComponent(JSON.stringify(queryParams));
                var form = $('<form action="' + url + '" target="_blank" method="post"><input type="text" name="exportParam" value="' +
                    exportParam
                    + '"/></form>').appendTo('body');
                form.submit();
                setTimeout(function () {
                    form.remove();
                }, 100);
                exportWindow.modal('hide');
            }
        });
    })();

</script>
</body>
</html>
